<?php
defined('BY_JYA') or exit('error');
$list = array(
			array('title'=>'特色-购物','list'=>array(
							//array('name'=>'jy_cashier','title'=>'收银台','desc'=>'线上线下收银','icon'=>'',),
							array('name'=>'jy_pingdd_pin','title'=>'拼多多百人拼团','desc'=>'百人拼团，抽中3人(不中则奖励)','icon'=>'',),
							array('name'=>'jy_merch','title'=>'多商户','desc'=>'多商户,多商家开店','icon'=>'',),
							array('name'=>'jy_creditshop','title'=>'积分商城','desc'=>'让积分产生二次消费','icon'=>'',),
			)),
			array('title'=>'活动-购物','list'=>array(
							array('name'=>'jy_weishop','title'=>'小程序直播','desc'=>'自主开播,无需第三方','image'=>'../addons/jy_weishop/images/icon_store.jpg','actionurl'=>'jy_weishop/activity.live.index/'),
							array('name'=>'jy_weishop','title'=>'今日运势','desc'=>'借势购物,魔性流量','image'=>'../addons/jy_weishop/images/icon_yunshi.jpg','actionurl'=>'jy_weishop/activity.sales.luck/'),
							array('name'=>'jy_weishop','title'=>'今日特价','desc'=>'经典日新,线下原型','image'=>'../addons/jy_weishop/images/icon_tejia.jpg','actionurl'=>'jy_weishop/activity.sales.offer/'),
							array('name'=>'jy_weishop','title'=>'今日省钱','desc'=>'快消品,必备502胶水','image'=>'../addons/jy_weishop/images/icon_sheng.jpg','actionurl'=>'jy_weishop/activity.sales.feemoney/'),
							array('name'=>'jy_weishop','title'=>'互动游戏','desc'=>'游戏营销,海量扩展','image'=>'../addons/jy_weishop/images/icon_game.jpg','actionurl'=>'jy_weishop/game.list/'),
							array('name'=>'jy_seckill','title'=>'整点秒杀','desc'=>'定时秒杀，刺激活跃','icon'=>'',),
							array('name'=>'jy_weishop','title'=>'预售','desc'=>'先预订，后消费','image'=>'../addons/jy_weishop/images/icon_yusou.jpg','actionurl'=>'jy_weishop/activity.presell.list/'),
							array('name'=>'jy_weishop','title'=>'预约核销','desc'=>'线上预约，线下消费','image'=>'../addons/jy_weishop/images/icon_hexiao.jpg','actionurl'=>'jy_weishop/store.verifylog/'),
							array('name'=>'jy_poster','title'=>'超级海报','desc'=>'用海报的形式宣传','icon'=>'',),
							array('name'=>'jy_giftbao','title'=>'购物送礼包/权益包','desc'=>'实现线上购物送礼包/权益包','icon'=>'',),
			)),
			array('title'=>'商城-工具','list'=>array(
							array('name'=>'jy_merch','title'=>'掌上商家','desc'=>'商家手机打理店铺','icon'=>'',),
							array('name'=>'jy_peisong','title'=>'掌上配送员','desc'=>'配送员手机管理配送','icon'=>'',),
							array('name'=>'jy_hwq','title'=>'好物圈','desc'=>'一键推送商品到微信好物圈','icon'=>'',),
							array('name'=>'jy_kefu','title'=>'全网客服','desc'=>'7种客服方式选择','icon'=>'',),
							array('name'=>'jy_echarts','title'=>'大数据可视化屏幕','desc'=>'大屏幕，科技感十足','icon'=>'',),
			)),
			array('title'=>'商城-拓展','list'=>array(
							array('name'=>'jy_diypage','title'=>'店铺装修','desc'=>'动动鼠标搭建个性店铺','icon'=>'',),
							array('name'=>'jy_weishopniu','title'=>'电商客千牛','desc'=>'专注电商客商品批量操作','icon'=>'',),
			)),
			array('title'=>'商城-游戏','list'=>array(
							array('name'=>'jy_bigwheel','title'=>'大转盘','desc'=>'随时随地，大转盘','icon'=>''),
							array('name'=>'jy_red_rain','title'=>'红包雨','desc'=>'随时随地，触发红包雨','icon'=>''),
							array('name'=>'jy_red_pin','title'=>'拼红包','desc'=>'随时随地，拼红包','icon'=>''),
			)),
);
//判断是否基本设置了
$inplugins=array();
$noplugins=array();
$legaoplugins=array();
$setplugins = $this->plugin_setting('setplugins');
foreach($list as $k=>&$type){
		foreach($type['list'] as $i=>&$p){
			$install = check_permission($p['name']);
			$plugin=pdo_get('core_plugins',array('name'=>$p['name']),array('title','image','hide'));
			if($plugin['hide']){
				unset($type['list'][$i]);
			}
			if($install){
				$p['title']=$p['name']!='jy_weishop' && $plugin['title']?$plugin['title']:$p['title'];
				$p['image']=$p['image']?:$plugin['image'];
				$p['is_install'] = 1;
				$p['is_show'] = 1;
			}else{
				$noplugins[]=$p['name'];
				//unset($type['list'][$i]);
				$p['is_install'] = 0;
				$p['is_show'] = 0;
				if($_SESSION['isfounder']){
					$p['is_show'] = 1;
				}
			}
			foreach($setplugins as $name=>&$pv){
					if($pv['status']==0 && $name && $name == $p['name']){
						$p['is_show'] = 0;
					}
			}
		}
}
return  $list;
?>